package com.ler.yrmall.member.api;

import com.ler.yrmall.member.dto.MemberDTO;
import com.ler.yrmall.member.dto.MemberReceiveAddressDTO;
import com.ler.yrmall.basic.Result;

import java.util.List;

/**
 * @author Leron
 * @version 1.0
 */
public interface MemberApi {

    /**
     * 根据用户名获取
     * @param username
     * @return
     */
    Result<MemberDTO> getMemberByUsername(String username);

    /**
     * 获取会员收货地址
     * @param addressId
     * @return
     */
    Result<MemberReceiveAddressDTO> getMemberAddress(long addressId);

    /**
     * 地址列表
     * @return
     */
    Result<List<MemberReceiveAddressDTO>> getAddressList();

    /**
     * 默认收货地址
     * @return
     */
    Result<MemberReceiveAddressDTO> getDefaultAddress();

    /**
     * 会员总数量
     * @return
     */
    Long getMemberCount();

}
